package day04;

import java.util.Scanner;

public class CommandBySwitch {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);//新建一个扫描仪
        System.out.println("请选择功能：1.存款 2.取款 3.转帐 4.退出");//输入
        int command = scan.nextInt();//赋值

        switch(command){
            case 1:
                System.out.println("存款业务...");
                break;
            case 2:
                System.out.println("取款业务...");
                break;
            case 3:
                System.out.println("转账业务...");
                break;
            case 4:
                System.out.println("退出成功");
                break;
        }

        if (command==1) {
            System.out.println("存款业务");
        }else if(command==2){
            System.out.println("取款业务");
        }else if(command==3){
            System.out.println("转账业务");
        }else if(command==4){
            System.out.println("退出成功");
        }


    }
}
